package com.orderVideo.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

/**
 * 订单表
 * @TableName order
 */
@TableName(value ="orders")
@Data
public class Order implements Serializable {
    /**
     * 
     */
    @TableId(value = "order_id", type = IdType.AUTO)
    private Long orderId;

    /**
     * 订单关联用户
     */
    @TableField(value = "user_id")
    private Long userId;

    @TableField(value = "order_name")
    private String orderName;

    /**
     * 订单状态（1-处理中 2-已到账）
     */
    @TableField(value = "order_status")
    private Integer orderStatus;

    /**
     * 订单创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @TableField(value = "order_time")
    private LocalDateTime orderTime;

    /*
     * 订单金额
     */
    private BigDecimal orderMoney;

    @TableField(exist = false)
    private String userName;
    @TableField(exist = false)
    private String nickName;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;


}